﻿using System.Diagnostics;

namespace GameToolkit.BehaviourTree
{
    // 节点名字和描述
    [Conditional("UNITY_EDITOR")]
    [System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple = false)]
    public class CompositeTitleAttribute : System.Attribute
    {
        public string Title { get; set; }
        public string Description { get; set; }
        public CompositeTitleAttribute() { }
        public CompositeTitleAttribute(string title) { this.Title = title; }
    }

    // 节点图标
    [Conditional("UNITY_EDITOR")]
    [System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple = false)]
    public class CompositeIconAttribute : System.Attribute
    {
        public string Icon { get; set; }
        public CompositeIconAttribute() { }
        public CompositeIconAttribute(string icon) { this.Icon = icon; }
    }

    // 节点类别组名称
    [Conditional("UNITY_EDITOR")]
    [System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple = false)]
    public class CompositeCategoryAttribute : System.Attribute
    {
        public string Category { get; set; }
        public CompositeCategoryAttribute() { }
        public CompositeCategoryAttribute(string cate) { this.Category = cate; }
    }

    // 仅允许作为装饰节点使用
    [Conditional("UNITY_EDITOR")]
    [System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple = false)]
    public class DecorationCompositeOnlyAttribute: System.Attribute
    {

    }

    // 线程安全的标题
    public interface IThreadSafeTitle
    {
        string Title { get; }
    }

    public interface IAliveDescripter
    {
        string GetDescription();
    }
}
